<?php
	
class Table_Agence extends Zend_Db_Table_Abstract
{
    protected $_name    = 'agence';
    protected $_primary = 'AGENCE_NUMERO';
    protected $_sequence = true;
	
	 public function insertMannequin($numVip, $tailleMann){
                $data = array('VIP_NUMERO'=> $numVip, 'MANNEQUIN_TAILLE' => $tailleMann);
                $this->insert($data);
    }
	 
	public function getAgenceMannequin ($id) {
			
			$req=$this->select()
			->setIntegrityCheck(false)
			->from(array('ag' =>'agence'), array('*'))
			->join(array('apa' => 'apouragence'), 'ag.agence_numero = apa.agence_numero', array('*'))
			->join(array('m' => 'mannequin'), 'm.vip_numero = apa.vip_numero', array('*'))
			->where('m.vip_numero = ?', $id);
			
			$resu=$this->fetchRow($req);
			return $resu;
	}
	
}